<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    
</body>
</html>
<script>
    function sjs(min,max){
        return Math.floor(Math.random()*(max-min+1))+min
    }
    function Nums(num){
        var arr=[]
        for(i=0;i<num;i++){
            var sj=sjs(2,32)
            if(arr.indexOf(sj)==-1){
                arr.push(sj)
            }else{
                i--
            }
        }
        return arr;
    }
    console.log(Nums(10));
</script>